Next | Prev | Up | Top | Contents | Index

Source File Naming Conventions

Each compiler driver recognizes the type of an input file by the suffix assigned to the filename. Table 2-1 describes the possible filename suffixes.

Driver Input File Suffixes
SuffixDescription
.sAssembly source
.iPreprocessed source code in the language of the processing driver
.cC source
.C, .c++, .CC, .cc, .CPP, .cpp, .CXX, .cxxC++ source
.f, .F, .for, .FOR
.f, .f90, .F90
Fortran 77 source
Fortran 90 source
.pPascal source
.oObject file
.aObject library archive
.soDynamic shared object library

The following example compiles preprocessed source code:

f77 -c tickle.i

The Fortran 77 compiler, f77, assumes the file tickle.i contains Fortran statements (because the Fortran driver is specified). f77 also assumes the file has already been preprocessed (because the suffix is .i), and therefore does not invoke the preprocessor.


Next | Prev | Up | Top | Contents | Index